<template>
  <div class="search-form-component">
    <div class="layout-left">
      <slot></slot>
    </div>
    <div class="layout-right">
      <slot name="action"></slot>
    </div>
  </div>
</template>

<script>
export default {
  name: 'search-form'
}
</script>

<style lang="scss" scoped>
.search-form-component {
  display: flex;
  flex-wrap: wrap;

  .layout-left {
    flex: 1;
    min-width: 1px;
    min-height: 1px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    padding: 5px 0;

    ::v-deep .search-item-component {
      display: flex;
      align-items: center;
      flex: 0 0 auto;

      &:not(:last-child) {
        margin-right: 20px;
      }
    }
  }

  .layout-right {
    flex: 0 0 auto;
    padding: 5px 0 5px 10px;
  }
}
</style>
